//
//  ProductDetailCell2.m
//  FloatClouds
//
//  Created by 黄威 on 16/9/9.
//  Copyright © 2016年 黄威. All rights reserved.
//

#import "ProductDetailCell2.h"

@implementation ProductDetailCell2

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{

    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    
    if (self) {
        
        self.labelOfScore = [[BaseLabel alloc]init];
        self.labelOfScore.textColor = [UIColor grayColor];
        self.labelOfScore.text = @"综合评分:";
        self.labelOfScore.font = [UIFont fontWithName:@"Helvetica" size:17];
        [self.contentView addSubview:self.labelOfScore];
        
        self.labelOfScoreInput = [[BaseLabel alloc]init];
        self.labelOfScoreInput.textColor = [UIColor redColor];
        self.labelOfScoreInput.font = [UIFont fontWithName:@"Helvetica" size:17];
        [self.contentView addSubview:self.labelOfScoreInput];
        
        self.labelOfPrice = [[BaseLabel alloc]init];
        self.labelOfPrice.textColor = [UIColor grayColor];
        self.labelOfPrice.text = @"单盒价格:";
        self.labelOfPrice.font = [UIFont fontWithName:@"Helvetica" size:17];
        [self.contentView addSubview:self.labelOfPrice];
        
        
        self.labelOfPriceInput = [[BaseLabel alloc]init];
        self.labelOfPriceInput.textColor = [UIColor redColor];
        self.labelOfPriceInput.font = [UIFont fontWithName:@"Helvetica" size:17];
        [self.contentView addSubview:self.labelOfPriceInput];
     

        self.labelOftaste = [[BaseLabel alloc]init];
        self.labelOftaste.textColor = [UIColor grayColor];
        self.labelOftaste.text = @"口味得分:";
        self.labelOftaste.font = [UIFont fontWithName:@"Helvetica" size:17];
        [self.contentView addSubview:self.labelOftaste];
        
        
        self.labelOftasteInput = [[BaseLabel alloc]init];
        self.labelOftasteInput.textColor = [UIColor redColor];
        self.labelOftasteInput.font = [UIFont fontWithName:@"Helvetica" size:17];
        [self.contentView addSubview:self.labelOftasteInput];

        
        self.labelOfView = [[BaseLabel alloc]init];
        self.labelOfView.textColor = [UIColor grayColor];
        self.labelOfView.text = @"外观得分:";
        self.labelOfView.font = [UIFont fontWithName:@"Helvetica" size:17];
       [self.contentView addSubview:self.labelOfView];
        
        
        self.labelOfViewInput = [[BaseLabel alloc]init];
        self.labelOfViewInput.textColor = [UIColor redColor];
        self.labelOfViewInput.font = [UIFont fontWithName:@"Helvetica" size:17];
        [self.contentView addSubview:self.labelOfViewInput];
        
        self.labelOfCostPerformance = [[BaseLabel alloc]init];
        self.labelOfCostPerformance.textColor = [UIColor grayColor];
        self.labelOfCostPerformance.text = @"性价比分:";
        self.labelOfCostPerformance.font = [UIFont fontWithName:@"Helvetica" size:17];
        [self.contentView addSubview:self.labelOfCostPerformance];

        
        self.labelOfCostPerformanceInput = [[BaseLabel alloc]init];
        self.labelOfCostPerformanceInput.textColor = [UIColor redColor];
        self.labelOfCostPerformanceInput.font = [UIFont fontWithName:@"Helvetica" size:17];
        [self.contentView addSubview:self.labelOfCostPerformanceInput];
        
        self.fen1 = [[BaseLabel alloc]init];
        self.fen2 = [[BaseLabel alloc]init];
        self.fen3 = [[BaseLabel alloc]init];
        self.fen4 = [[BaseLabel alloc]init];
        self.fen1.textColor = [UIColor redColor];
        self.fen1.text = @"分";
        self.fen2.textColor = [UIColor redColor];
        self.fen2.text = @"分";
        self.fen3.textColor = [UIColor redColor];
        self.fen3.text = @"分";
        self.fen4.textColor = [UIColor redColor];
        self.fen4.text = @"分";
        self.fen1.font = [UIFont fontWithName:@"Helvetica" size:17];
        self.fen2.font = [UIFont fontWithName:@"Helvetica" size:17];
        self.fen3.font = [UIFont fontWithName:@"Helvetica" size:17];
        self.fen4.font = [UIFont fontWithName:@"Helvetica" size:17];
        [self.contentView addSubview:self.fen1];
        [self.contentView addSubview:self.fen2];
        [self.contentView addSubview:self.fen3];
        [self.contentView addSubview:self.fen4];
        
    }

    return self;
}

- (void)layoutSubviews{

    [super layoutSubviews];
    
    self.labelOfScore.frame = CGRectMake(10, 10, self.bounds.size.width *0.25, self.bounds.size.height *0.18);
    self.labelOfScoreInput.frame = CGRectMake(self.bounds.size.width *0.25 + 10, 10, self.bounds.size.width *0.1, self.bounds.size.height * 0.18);
    
    self.labelOfCostPerformance.frame = CGRectMake(10, self.bounds.size.height * 0.18 +10, self.bounds.size.width *0.25, self.bounds.size.height *0.18 );
    self.labelOfCostPerformanceInput.frame = CGRectMake(self.bounds.size.width *0.25 + 10, self.bounds.size.height * 0.18 +10, self.bounds.size.width *0.1, self.bounds.size.height * 0.18);

    self.labelOftaste.frame = CGRectMake(10, self.bounds.size.height * 0.18 *2 +10, self.bounds.size.width *0.25, self.bounds.size.height *0.18 );
    self.labelOftasteInput.frame = CGRectMake(self.bounds.size.width *0.25 + 10, self.bounds.size.height * 0.18 * 2 +10, self.bounds.size.width *0.1, self.bounds.size.height * 0.18);

    self.labelOfView.frame = CGRectMake(10, self.bounds.size.height * 0.18 *3 +10, self.bounds.size.width *0.25, self.bounds.size.height *0.18 );
    self.labelOfViewInput.frame = CGRectMake(self.bounds.size.width *0.25 + 10, self.bounds.size.height * 0.18 * 3 +10, self.bounds.size.width *0.1, self.bounds.size.height * 0.18);


    self.labelOfPrice.frame =  CGRectMake(10, self.bounds.size.height * 0.18 *4 +10, self.bounds.size.width *0.25, self.bounds.size.height *0.18 );
    self.labelOfPriceInput.frame = CGRectMake(self.bounds.size.width *0.25 + 10, self.bounds.size.height * 0.18 * 4 +10, self.bounds.size.width *0.3, self.bounds.size.height * 0.18);
    
    
    self.fen1.frame = CGRectMake(self.bounds.size.width *0.35 + 10, self.bounds.size.height * 0.18 + 10, self.bounds.size.width *0.3, self.bounds.size.height * 0.18);

    self.fen2.frame = CGRectMake(self.bounds.size.width *0.35 + 10, self.bounds.size.height * 0.18 * 2 +10, self.bounds.size.width *0.3, self.bounds.size.height * 0.18);
    
    self.fen3.frame = CGRectMake(self.bounds.size.width *0.35 + 10, self.bounds.size.height * 0.18 * 3 +10, self.bounds.size.width *0.3, self.bounds.size.height * 0.18);
    
    self.fen4.frame = CGRectMake(self.bounds.size.width *0.35 + 10, 10, self.bounds.size.width *0.3, self.bounds.size.height * 0.18);
    
}




@end
